function createInfoWindow(title: string, content: string, callback: any) {
  const info = document.createElement('div')
  info.className = 'custom-info input-card content-window-card'

  //可以通过下面的方式修改自定义窗体的宽高
  info.style.width = '400px'
  // 定义顶部标题
  const top = document.createElement('div')
  // const titleD = document.createElement("div");
  const closeX = document.createElement('img')
  top.className = 'info-top'

  closeX.src = require('@/assets/image/icon/point.png')
  closeX.onclick = callback

  // top.appendChild(titleD);
  top.innerHTML = title
  top.appendChild(closeX)
  info.appendChild(top)

  // 定义中部内容
  const middle = document.createElement('div')
  middle.className = 'info-middle'
  middle.style.backgroundColor = 'white'
  middle.innerHTML = content
  info.appendChild(middle)

  // 定义底部内容
  const bottom = document.createElement('div')
  bottom.className = 'info-bottom'
  bottom.style.position = 'relative'
  bottom.style.top = '0px'
  bottom.style.margin = '0 auto'
  info.appendChild(bottom)
  return info
}

export default {
  createInfoWindow,
}
